package com.yida.gwj.expend.outside.service;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.yida.gwj.expend.outside.domain.GwjMaintenanceFundsBusinessHouse;
import com.yida.gwj.expend.outside.domain.dto.AllocatedAmountListDTO;
import com.yida.gwj.expend.outside.domain.dto.OwnerCommentsDetailDTO;
import com.yida.gwj.expend.outside.domain.request.AllocatedAmountRequest;
import com.yida.gwj.expend.outside.domain.request.GwjInsertHouseRequest;

/**
 * 业务房屋信息Service接口
 *
 * @author lgp
 * @date 2023-02-20
 */
public interface IGwjMaintenanceFundsBusinessHouseService {
    /**
     * 查询业务房屋信息
     *
     * @param businessHouseId 业务房屋信息主键
     * @return 业务房屋信息
     */
    GwjMaintenanceFundsBusinessHouse selectGwjMaintenanceFundsBusinessHouseByBusinessHouseId(Long businessHouseId);

    /**
     * 查询业务房屋信息列表
     *
     * @param gwjMaintenanceFundsBusinessHouse 业务房屋信息
     * @return 业务房屋信息集合
     */
    List<GwjMaintenanceFundsBusinessHouse> selectGwjMaintenanceFundsBusinessHouseList(GwjMaintenanceFundsBusinessHouse gwjMaintenanceFundsBusinessHouse);

    /**
     * 新增业务房屋信息
     *
     * @param gwjMaintenanceFundsBusinessHouse 业务房屋信息
     * @return 结果
     */
    GwjMaintenanceFundsBusinessHouse insertGwjMaintenanceFundsBusinessHouse(GwjMaintenanceFundsBusinessHouse gwjMaintenanceFundsBusinessHouse);

    /**
     * 批量新增基础数据（房屋）
     *
     * @param houses 基础数据（房屋）
     * @return 结果
     */
    int insertGwjMaintenanceFundsBusinessHouseList(List<GwjInsertHouseRequest> houses);

    /**
     * 修改业务房屋信息
     *
     * @param gwjMaintenanceFundsBusinessHouse 业务房屋信息
     * @return 结果
     */
    int updateGwjMaintenanceFundsBusinessHouse(GwjMaintenanceFundsBusinessHouse gwjMaintenanceFundsBusinessHouse);

    /**
     * 批量删除业务房屋信息
     *
     * @param businessHouseIds 需要删除的业务房屋信息主键集合
     * @return 结果
     */
    int deleteGwjMaintenanceFundsBusinessHouseByBusinessHouseIds(Long[] businessHouseIds);

    /**
     * 删除业务房屋信息信息
     *
     * @param businessHouseId 业务房屋信息主键
     * @return 结果
     */
    int deleteGwjMaintenanceFundsBusinessHouseByBusinessHouseId(Long businessHouseId);

    /**
     * 删除业务房屋信息信息-通过业务ID
     *
     * @param bizId 业务房屋信息主键
     * @return 结果
     */
    int deleteGwjMaintenanceFundsBusinessHouseByBusinessId(Long bizId);

    /**
     * 查询业务房屋信息-通过业务ID
     *
     * @param bizId 业务房屋信息主键
     * @return 业务房屋信息
     */
    GwjMaintenanceFundsBusinessHouse selectGwjMaintenanceFundsBusinessHouseByBusinessId(Long bizId);

    /**
     * 批量修改业务房屋信息
     *
     * @param maintenanceFundsBusinessHouseList 维修基金业务列表
     * @return 业务房屋信息
     */
    int updateBatchGwjMaintenanceFundsBusinessHouse(@Param("maintenanceFundsBusinessHouseList") List<GwjMaintenanceFundsBusinessHouse> maintenanceFundsBusinessHouseList);

    /**
     * 查询业务房屋信息列表
     *
     * @param allocatedAmountRequest 业务房屋信息
     * @return 业务房屋信息集合
     */
    List<AllocatedAmountListDTO> allocatedAmountList(AllocatedAmountRequest allocatedAmountRequest);

    /**
     * 插入批gwj维修基金业务
     *
     * @param maintenanceFundsBusinessHouse 维修基金业务房子
     * @return int
     */
    int insertBatchGwjMaintenanceFundsBusinessHouse(List<GwjMaintenanceFundsBusinessHouse> maintenanceFundsBusinessHouse);

    /**
     * 查询未选中房屋列表
     *
     * @param allocatedAmountRequest 业务房屋信息
     * @return 业务房屋信息集合
     */
    List<GwjMaintenanceFundsBusinessHouse> selectCancelHouseList(AllocatedAmountRequest allocatedAmountRequest);

    /**
     * 查询房屋用途列表
     *
     * @return {@link List}<{@link String}>
     */
    List<String> selectUseTypeList();

    // ------------------------新增功能区 20230630 hmh start----------------------------------
    /**
     * 根据业务ID和房屋标识码查询房屋数据
     * 
     * @param bizId 业务ID
     * @param houseCode 房屋标识码
     * @return
     */
    GwjMaintenanceFundsBusinessHouse selectGwjMaintenanceFundsBusinessHouseByBizIdAndHouseCode(Long bizId, String houseCode);

    /**
     * 根据业务ID和房屋编号进行批量更新
     * 
     * @param list 房屋数据集合
     * @return
     */
    int updateBatchMaintenanceFundsBusinessHouseByBizIdAndHouseCode(List<GwjMaintenanceFundsBusinessHouse> list);
    // ------------------------end -----------------------------------------------------------

    /**
     * 查询业主征求意见房屋信息
     * 
     * @param bizId 业务主键
     * @return
     */
    List<OwnerCommentsDetailDTO> selectOwnerCommentsDetailList(Long bizId);

}
